package com.hksj.gas.mapper;


import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.hksj.cbm.entity.DeviceInstance;
import com.hksj.gas.dto.GasLargeScreenDTO;
import com.hksj.gas.vo.*;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface GasLargeScreenMapper {
    //查询设备在线情况统计
    GasDeviceStatsVO queryGasDeviceStats(@Param("dto") GasLargeScreenDTO dto);

    //查询分类设备在线情况统计
    List<GasDeviceStatsByTypeVO> queryGasDeviceStatsByType(@Param("dto") GasLargeScreenDTO dto);

    //查询设备列表
    List<GasDeviceStatsListVO> queryGasDeviceStatsList(@Param("dto") GasLargeScreenDTO dto, @Param("page") IPage<GasDeviceStatsListVO> page);

    //查询当前报警设备情况
    GasAlarmDeviceVO queryAlarmDevice(@Param("dto") GasLargeScreenDTO dto);

    List<GasAlarmDeviceDetailsVO> queryGasAlarmDeviceDetailsList(@Param("dto") GasLargeScreenDTO dto);

    List<GasHistoryAlarmDeviceVO> queryGasHistoryAlarmDeviceByTime(@Param("dto") GasLargeScreenDTO dto);

    List<GasAlarmDeviceTypeVO> queryGasAlarmDeviceByType(@Param("dto") GasLargeScreenDTO dto);

    List<DeviceInstance> queryGasProductId (@Param("dto") GasLargeScreenDTO dto);

    @DS("TAOS")
    List<ProductFlowVO> queryProductIdDailyFlow(@Param("tableName") String tableName, @Param("deviceIdList") List<String> deviceIdList);

    List<GasAlarmDeviceTypeVO> queryGasDeviceType();
}